/**
 ******************************************************
 * 作者:朱雍
 * 备注:
 * 时间:2017年3月15日上午11:12:58
 * Copyright (c) 2017, 243813208@qq.com All Rights Reserved.
 ******************************************************
 */

package cn.sxt.yxl.question.pojo;

import java.util.Date;

/**
 * 类名:AColumns 
 * 备注:	 
 * 时间:2017年3月15日 上午11:12:58
 * 作者:朱雍
 * @since  	JDK 1.8	 
 */
public class AColumns {

	private int id;
	private String name;
	private String content;
	private String url;
	private byte flag;
	private byte status;
	private Date createTime;
	private Date updateTime;
	private Date pubTime;
	private String statusStr;
	private String falgStr;
	
	
	public void setPubTime(Date pubTime) {
		this.pubTime = pubTime;
	}
	public String getStatusStr() {
		AColumnsEnum[] columnsEnums = AColumnsEnum.values();
		for (AColumnsEnum aColumnsEnum : columnsEnums) {
			if(aColumnsEnum.toString().startsWith("STATUS_") && aColumnsEnum.getStatus() == this.getStatus()){
				this.statusStr = aColumnsEnum.getName();
			}
				
		}
		return statusStr;
	}
	public String getFalgStr() {
		AColumnsEnum[] columnsEnums = AColumnsEnum.values();
		for (AColumnsEnum aColumnsEnum : columnsEnums) {
			if(aColumnsEnum.toString().startsWith("FLAG_") && aColumnsEnum.getStatus() == this.getFlag()){
				this.falgStr = aColumnsEnum.getName();
			}
				
		}
		return falgStr;
	}
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getContent() {
		return content;
	}
	public void setContent(String content) {
		this.content = content;
	}
	public String getUrl() {
		return url;
	}
	public void setUrl(String url) {
		this.url = url;
	}
	public byte getFlag() {
		return flag;
	}
	public void setFlag(byte flag) {
		this.flag = flag;
	}
	public byte getStatus() {
		return status;
	}
	public void setStatus(byte status) {
		this.status = status;
	}
	public Date getCreateTime() {
		return createTime;
	}
	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}
	public Date getUpdateTime() {
		return updateTime;
	}
	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}
	public Date getPubTime() {
		return pubTime;
	}
	
}

